#ifndef FILEPARSER_HPP
# define FILEPARSER_HPP

# include <set>
# include <string>

# include "Puzzle.hpp"

class FileParser
{
public:
    FileParser(Puzzle& puzzle);
    virtual ~FileParser();

    bool parse(std::string const & path);

private:
    bool _addLine(std::string const & line);
    unsigned int _getLineSize(std::string const & line);
    bool _isValide() const;
    bool _isCommentLine(std::string const & line) const;

private:
    Puzzle& _puzzle;
    int _nbLine;
    int _lineSize;
    std::set<unsigned int> _addedValues;
};

#endif // FILEPARSER_HPP
